<?php

class Region extends CActiveRecord{
	
	public static function model($className=__CLASS__)
    {
        return parent::model($className);
    }
	
	public function tableName()
	{
		return '{{region}}';
	}
	
	public function relations()
    {
        return array(
            'widgets'=>array(self::MANY_MANY, 'WidgetInstance',
                '{{widgetinstance_region}}(region_id, widgetinstance_id)'),
        );
    }
}
